<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<body>
    <script>
        //原来的数组改变
        
        var arr1=[11,22,33,44]
        var pop1=arr1.pop()//弹出并返回数组最后一个值
        console.log("arr1",arr1)//11,22,33
        console.log("pop1",pop1)//44

        var arr2=[11,22,33,44]
        arr2.push(55,66)//在数组最后加值
        console.log("arr2",arr2)//11,22,33,44,55
        
        var arr3=[11,22,33,44]
        arr3.unshift(55,66)//在数组最前面加值
        console.log("arr3",arr3)//55,66,11,22,33,55

        var arr4=[11,22,33,44]
        var shift4=arr4.shift()//删除数组第一个值
        console.log("arr4",arr4)//22，33，44
        console.log("shift4", shift4)//11
    </script>
</body>
</html>